<html>
<head>
    <css file="__PUBLIC__/css/body.css"/>
    <css file="__STATIC__/icon/icon.css"/>
    <css file="__STATIC__/wbElement/wbElement.css"/>
    <js file="__STATIC__/jquery-1.7.2.min.js"/>
    <js file="__STATIC__/wbElement/wbElement.js"/>
    <style type="text/css">
        .tdh tr td{height:30px;}
        .lock div{float:left;}
        .lock span{float:left;margin-left:3px;}
    </style>
</head>
<body>
<form action="{:U('Rbac/accessHandle')}" method='post'>
    <div class="top">
        <div class="position"><span class="icon icon-31"></span>当前位置：角色权限配置</div>
        <div class="top-title">
            <span class="icon icon-32"></span>
            <div class="top-tool">
                <a class="button-a" href="{:U('Rbac/role')}">返回</a>
                <input class="button-b" type="submit" value="提交保存"/>
                <input type="hidden" value="{$rid}" name="rid"/>
            </div>
        </div>
    </div>
    <div class="body">
         <foreach name='node' item='app'>
            <input type="hidden" name="access[]" value="{$app.id}_1"/>
            <table class="list-tb tdh" style="float: left;"  border="0" cellpadding="0" cellspacing="0">
                <foreach name='app.child' item='action'>
                    <input type="hidden" name="access[]" value="{$action.id}_2" />
                    <tr>
                        <td width="13%" class="textRight" style="font-weight: bold;">
                           {$app.title}-{$action.title}：
                        </td>
                        <foreach name='action.child' item='method'>
                            <td class="lock">
                                <div class="checkbox" checkbox="" style="height:12px;width:12px;" wname="access[]" value="{$method.id}_3" level="3" <if condition='$method["access"]'>checked='checked'</if>></div>
                                <span>{$method.title}</span>
                            </td>
                        </foreach>
                    </tr>
                </foreach>
          </table>
      </foreach>
    </div>
</form>
</body>
</html>